Remove faulty and irrelevant enter-leave compression code. (#449167, patch
authorMatthias Clasen <mclasen@redhat.com>
Thu, 21 Jun 2007 05:21:51 +0000 (05:21 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Thu, 21 Jun 2007 05:21:51 +0000 (05:21 +0000)
2007-06-21  Matthias Clasen  <mclasen@redhat.com>

        * gtk/gtkmain.c (gtk_main_do_event): Remove faulty and irrelevant
        enter-leave compression code.  (#449167, patch by Tim Janik)

svn path=/trunk/; revision=18213

ChangeLog
gtk/gtkmain.c

index 8eff0486db4421cc7f0e5a6e65558d31e64051e8..353b91d9f88cecf5c5b97ba71a271a12eb3c35d0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-06-21  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkmain.c (gtk_main_do_event): Remove faulty and irrelevant
+       enter-leave compression code.  (#449167, patch by Tim Janik)
+
 2007-06-19  Johan Dahlin  <jdahlin@async.com.br>
 
        * gdk/quartz/GdkQuartzView.c ([GdkQuartzView -updateTrackingRect]): Fix a typo
index 3da053bcee631b2e3c247c91e2c0db7bd3875682..910d93fb2a49d2cb20a8597269686aa6dfac6a69 100644 (file)
@@ -1377,42 +1377,9 @@ gtk_main_do_event (GdkEvent *event)
   GtkWidget *event_widget;
   GtkWidget *grab_widget;
   GtkWindowGroup *window_group;
-  GdkEvent *next_event;
   GdkEvent *rewritten_event = NULL;
   GList *tmp_list;
 
-  /* If there are any events pending then get the next one.
-   */
-  next_event = gdk_event_peek ();
-  
-  /* Try to compress enter/leave notify events. These event
-   *  pairs occur when the mouse is dragged quickly across
-   *  a window with many buttons (or through a menu). Instead
-   *  of highlighting and de-highlighting each widget that
-   *  is crossed it is better to simply de-highlight the widget
-   *  which contained the mouse initially and highlight the
-   *  widget which ends up containing the mouse.
-   */
-  if (next_event)
-    if (((event->type == GDK_ENTER_NOTIFY) ||
-        (event->type == GDK_LEAVE_NOTIFY)) &&
-       ((next_event->type == GDK_ENTER_NOTIFY) ||
-        (next_event->type == GDK_LEAVE_NOTIFY)) &&
-       (next_event->type != event->type) &&
-       (next_event->any.window == event->any.window))
-      {
-       /* Throw both the peeked copy and the queued copy away 
-        */
-       gdk_event_free (next_event);
-       next_event = gdk_event_get ();
-       gdk_event_free (next_event);
-       
-       return;
-      }
-
-  if (next_event)
-    gdk_event_free (next_event);
-
   if (event->type == GDK_SETTING)
     {
       _gtk_settings_handle_event (&event->setting);